package com.yiman.framework.web.page;

import com.yiman.common.utils.ServletUtils;

/**
 * @author: Mr.yang
 * @create: 2019-06-14
 **/
public class TableSupport {
    /**
     * 封装分页对象
     */
    public static PageDomain getPageDomain() {
        PageDomain pageDomain = new PageDomain();
        pageDomain.setPageNum(ServletUtils.getParameterToInt("page"));
        pageDomain.setPageSize(ServletUtils.getParameterToInt("limit"));
        return pageDomain;
    }

    public static PageDomain buildPageRequest() {
        return getPageDomain();
    }
}
